<%@ page language="java" contentType="text/html; charset=utf-8"    pageEncoding="utf-8"%>
<%@include file="header.jsp"%>
<script language="JavaScript" type="text/javascript" src="../datePicker/WdatePicker.js"></script>
<style type="text/css">
<!--
body {
	margin-left: 0px;
	margin-top: 0px;
	margin-right: 0px;
	margin-bottom: 0px;
}
.STYLE1 {
	color: #666666;
	font-weight: bold;
}
.STYLE5 {color: #666666}
.STYLE6 {
	color: #135294;
	font-weight: bold;
}
-->
</style>
<form method="post" action="queryOrder.action">
 <table width="95%" border="1" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" align="center">
 	<tr>
 		<td  colspan="4" background="images/bg_table.jpg" bgcolor="#ECEAE6" align="center">查询</td>
 	</tr>
	<tr bgcolor='#F1F3F5'>
 		<td width="11%">订单状态</td>
 		<td width="29%">
 		<select name="orderStatus">
 				<option value="-1" <s:if test="  orderStatus==-1 ">selected</s:if> >请选择</option>
 				<option value="0" <s:if test="  orderStatus==0 ">selected</s:if> >未交款</option>
 				<option value="1" <s:if test="  orderStatus==1 ">selected</s:if> >已交款</option>
 				<option value="2" <s:if test="  orderStatus==2 ">selected</s:if>>已发货</option>
 				<option value="3" <s:if test="  orderStatus==3 ">selected</s:if>>已收到</option>
 				<option value="4" <s:if test="  orderStatus==4 ">selected</s:if>>退货</option>
 				<option value="5" <s:if test="  orderStatus==5 ">selected</s:if>>完成</option>
 			</select>
 			  </td>
 		<td width="7%">时间</td> 		 
	  <td width="53%">
	  	<input class="Wdate" type="text" id="beginDate" name="beginDate" value="<s:property value='beginDate'/>"  onFocus="WdatePicker({isShowClear:false,readOnly:false})"/>
	  		-
	  	<input class="Wdate" type="text" id="endDate" name="endDate" value="<s:property value='endDate'/>" onFocus="WdatePicker({isShowClear:false,readOnly:false})"/>
  	  </td>
	</tr>	
	<tr>
		<td  colspan="4"    nowrap background="images/bg_table.jpg" bgcolor="#ECEAE6"  align="center"><input type="submit" /></td>
	</tr>
</table> 
</form>
<br/>
<div align="center">订单列表</div>
 <table width="98%" border="0" cellpadding="3" cellspacing="2" bgcolor="#FFFFFF" align="center">
 	<tr>
 		<td width="15%" nowrap background="images/bg_table.jpg" bgcolor="#ECEAE6">订单号</td>
		<td width="15%" nowrap background="images/bg_table.jpg" bgcolor="#ECEAE6">产品名称</td>
 		<td width="30%" nowrap background="images/bg_table.jpg" bgcolor="#ECEAE6">用户备注</td>
 		<td width="15%" nowrap background="images/bg_table.jpg" bgcolor="#ECEAE6">电话</td>
 		<td width="10%" nowrap background="images/bg_table.jpg" bgcolor="#ECEAE6">日期</td>
 		<td width="15%" nowrap background="images/bg_table.jpg" bgcolor="#ECEAE6">订单状态</td>
 	</tr>
 	<s:iterator value="qryOrders">
 	<tr bgcolor='#F1F3F5' onmouseover = "this.style.backgroundColor = '#FFDCB0'" onmouseout = "this.style.backgroundColor = ''" style=''>
 		<td>
 			<a href="orderDetail.action?orderSeq=<s:property value='orderSeq'/>" target="_blank"><s:property value="orderSeq"/></a>
 		</td>
		<td><s:property value="name"/></td>
		<td><s:property value="userMemo"/></td>
		<td><s:property value="telnumber"/> <s:property value="mobile"/></td>
 		<td><s:date  name='createtime'  format="yyyy-MM-dd HH:mm:ss" /></td>
		<td>
			<s:if test="status==0">未交款  <a href="deleOrder.action?orderSeq=<s:property value='orderSeq'/>" onclick="javascript:if(confirm('确定删除该订单吗')) return true; else return false;">删除</a> </s:if>
			<s:if test="status==1">已交款</s:if>
			<s:if test="status==2">已发货</s:if>
			<s:if test="status==3">已收到</s:if>
			<s:if test="status==4">退货</s:if>
			<s:if test="status==5">完成</s:if>	
		</td>
 	</tr>
 	</s:iterator>
 	<tr><td colspan="6" nowrap  bgcolor='#E4EDF9'>
 		<a href="orderList.action?currentPage=<s:property value='prevPage'/>">上一页</a>
 		<a href="orderList.action?currentPage=<s:property value='nextPage'/>">下一页</a>
 		共<s:property value='totalPage'/>页
 	 
 	</td></tr>
 </table> 
  